package net.toocruel.iqismart.service.dto;

import net.toocruel.iqismart.entity.common.Area;
import net.toocruel.iqismart.entity.constants.Gender;
import org.hibernate.validator.constraints.Length;
import org.hibernate.validator.constraints.NotBlank;
import org.springframework.format.annotation.DateTimeFormat;
import org.springframework.web.multipart.MultipartFile;

import java.io.Serializable;
import java.util.Date;

/**
 * @Description
 * @Auther sty
 * @createTime 2018/5/17 上午10:57
 */
public class ProfileBaseDTO implements Serializable {

    private String username;
    @NotBlank(message = "不能为空")
    @Length(min = 4,max = 20,message = "长度为5-20")
    private String nickname;
    private String avatar;
    private Gender gender = Gender.PRIVATE;
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private Date birthday;
    private Area province;
    private Area city;
    private String title;
    private String qrcode;
    private MultipartFile qrcodeFile;
    private String description;

    public String getNickname() {
        return nickname;
    }

    public void setNickname(String nickname) {
        this.nickname = nickname;
    }

    public String getUsername() {
        return username;
    }

    public void setUsername(String username) {
        this.username = username;
    }

    public String getAvatar() {
        return avatar;
    }

    public void setAvatar(String avatar) {
        this.avatar = avatar;
    }

    public Gender getGender() {
        return gender;
    }

    public void setGender(Gender gender) {
        this.gender = gender;
    }

    public Date getBirthday() {
        return birthday;
    }

    public void setBirthday(Date birthday) {
        this.birthday = birthday;
    }

    public Area getProvince() {
        return province;
    }

    public void setProvince(Area province) {
        this.province = province;
    }

    public Area getCity() {
        return city;
    }

    public void setCity(Area city) {
        this.city = city;
    }

    public String getTitle() {
        return title;
    }

    public void setTitle(String title) {
        this.title = title;
    }

    public String getQrcode() {
        return qrcode;
    }

    public void setQrcode(String qrcode) {
        this.qrcode = qrcode;
    }

    public String getDescription() {
        return description;
    }

    public void setDescription(String description) {
        this.description = description;
    }

    public MultipartFile getQrcodeFile() {
        return qrcodeFile;
    }

    public void setQrcodeFile(MultipartFile qrcodeFile) {
        this.qrcodeFile = qrcodeFile;
    }
}
